package com.alibaba.citrus.ots.sales.plan.api.salesplan.publish;

import com.alibaba.citrus.ots.sales.plan.dto.api.request.DispatchPlanScItemRequest;
import com.alibaba.citrus.ots.sales.plan.dto.api.request.EditSalesPlanAdjustDetailRequest;
import com.alibaba.citrus.ots.sales.plan.dto.api.request.EditSalesPlanPublishRequest;
import com.alibaba.citrus.ots.sales.plan.sdo.SalesPlanAdjustDetailSDO;
import com.alibaba.citrus.ots.sales.plan.sdo.SalesPlanLineSDO;
import com.alibaba.citrus.ots.sales.plan.sdo.SalesPlanScItemExtendSDO;
import com.alibaba.lattice2.epoch.meshflow.model.annotation.MeshFlowService;
import com.alibaba.lattice2.epoch.sdk.model.Result;

import java.util.List;

/**
 * @author zls
 * @description: 月度计划发布相关接口
 * @date 2021-10-14 19:10
 */
@MeshFlowService(apps = {"bc_ots"}, name = "salesPlanPublishWriteService")
public interface SalesPlanPublishWriteService {
    /**
     * 批量插入
     * @param createList
     * @return
     */
    Result<Boolean> batchCreatePlanScItemExtend(List<SalesPlanScItemExtendSDO> createList);

    /**
     * 生成部门任务量
     *
     * @param dispatchPlanScItemRequest
     * @return
     */
    Result<Boolean> dispatchPlanScItemForDepartment(DispatchPlanScItemRequest dispatchPlanScItemRequest);

    /**
     * 生成客户任务量
     *
     * @param dispatchPlanScItemRequest
     * @return
     */
    Result<Boolean> dispatchPlanScItemForCustomer(DispatchPlanScItemRequest dispatchPlanScItemRequest);

    /**
     * 计划调整生成客户调整回复量
     * 生成
     * @param dispatchPlanScItemRequest
     * @return
     */
    Result<Boolean> dispatchPlanScItemForAdjust(DispatchPlanScItemRequest dispatchPlanScItemRequest);

    /**
     * 计划调整发布客户任务量
     * 发布
     * @param dispatchPlanScItemRequest
     * @return
     */
    Result<Boolean> publishPlanScItemForAdjust(DispatchPlanScItemRequest dispatchPlanScItemRequest);

    /**
     * 编辑部门任务量（失焦保存）
     *
     * @param editSalesPlanPublishRequest
     * @return
     */
    Result<SalesPlanScItemExtendSDO> editSalesPlanPublish(EditSalesPlanPublishRequest editSalesPlanPublishRequest);

    /**
     * 编辑部门任务量（失焦保存）导入使用
     *
     * @param editSalesPlanPublishRequest
     * @return
     */
    Result<SalesPlanScItemExtendSDO> editSalesPlanPublishForImport(EditSalesPlanPublishRequest editSalesPlanPublishRequest);

    /**
     * 编辑客户任务量（失焦保存）
     *
     * @param editSalesPlanDetailRequest
     * @return
     */
    Result<SalesPlanLineSDO> editSalesPlanDetail(EditSalesPlanPublishRequest editSalesPlanDetailRequest);

    /**
     * 编辑客户任务量（失焦保存）导入使用
     *
     * @param editSalesPlanDetailRequest
     * @return
     */
    Result<SalesPlanLineSDO> editSalesPlanDetailForImport(EditSalesPlanPublishRequest editSalesPlanDetailRequest);

    /**
     * 发布部门任务量
     *
     * @param dispatchPlanScItemRequest
     * @return
     */
    Result<Boolean> publishPlanScItemForDepartment(DispatchPlanScItemRequest dispatchPlanScItemRequest);

    /**
     * 重置部门任务量
     *
     * @param request
     * @return
     */
    Result<Boolean> resetPlanScItemForDepartment(DispatchPlanScItemRequest request);

    /**
     * 编辑调整客户任务量（失焦保存）
     *
     * @param editSalesPlanAdjustDetailRequest
     * @return
     */
    Result<SalesPlanAdjustDetailSDO> editSalesPlanAdjustDetail(EditSalesPlanAdjustDetailRequest editSalesPlanAdjustDetailRequest);

    /**
     * 批量导入添加调整明细(客户任务量)
     *
     * @param salesPlanAdjustDetailSDOList
     * @return
     */
    Result<String> batchImportCreateSalesPlanTaskAdjustDetail(List<SalesPlanAdjustDetailSDO> salesPlanAdjustDetailSDOList);
}
